<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN"
"http://www.w3.org/TR/html4/strict.dtd">

<html xmlns="http://www.w3.org/1999/xhtml" lang="en">

<head>
	<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
	<title></title>
	<link rel="stylesheet" href="<?php echo __ROOT__?>/resource/hm/css/submit.css">
	<link rel="stylesheet" href="<?php echo __ROOT__?>/resource/hm/css/winSkin.css">
	<script src="<?php echo __ROOT__?>/resource/hm/jquery-1.7.2.min.js" type="text/javascript" charset="utf-8"></script>
	<script src="<?php echo __ROOT__?>/resource/hm/js/submit.js" type="text/javascript" charset="utf-8"></script>
	<script src="<?php echo __ROOT__?>/resource/hm/area.js" type="text/javascript" charset="utf-8"></script>
	<script type="text/javascript">
		$(function(){
		//初始化方法
		area.init('area');
		})
	</script>
	</head>
</head>

<body>
	<!-- 最顶部登录list开始 -->
	<div id="login">
		<div class="tnr fr">
			<ul class="ul">
				<li  class="tu">
					<a href="">去购物车结算</a>
				</li>
				<li class="tu">
					<a href="">我的订单</a>
					<a href="">会员中心</a>
				</li>
				<li class="tu">
					<span>
					全国客服电话：
						<span class="em">400-883-2688</span>
					</span>
				</li>
				<li class="eol" id="member_link">
					<?php if($_SESSION['home']['username'] ){?>
						欢迎 <span style="color:red"><?php echo $_SESSION['home']['username'];?></span> 回来！
                        <a href="<?php echo u('logoin.out')?>" class="btn btn-danger" >退出</a>
					    <span class="caret"></span>
					<?php }else{?>
						<a href="<?php echo u('logoin.logo')?>" id="__AD_top_click_1.1_3" class="l_m">登录&nbsp;</a>
						<a href="<?php echo u('logoin.reg')?>" id="__AD_top_click_1.1_4" class="l_m" style="color: red">注册(即赠50元)</a>|
                    <?php }?>
				</li>
			</ul>
		</div>

	</div>

<div id="yigou">
<div class="yigou-top">
<div class="yi-logo">
<a href="">
	<img src="<?php echo __ROOT__?>/resource/hm/images/cart/logo-ico.jpg" style="margin-top: 20px;" />
</a>
</div>
<div class="yi-bg">
<ul>
	<li>
		<b style="background:#FFAA01;border-radius: 50%;">1</b>
		<span>我的购物车</span>
		<!--<b class="yi-bg-b1"></b>-->
	</li>
	<li>
		<b style="background:#FFAA01;border-radius: 50%;position: relative;z-index: 20;">2</b>
		<span>确认订单</span>
		<b class="steps"></b>
	</li>
	<li>
		<b>3</b>
		<span>付款</span>
	</li>
	<li>
		<b>4</b>
		<span>支付成功</span>
	</li>
</ul>
</div>
</div>
<div class="top-bottom">
<div class="top-bcheck">
<!--<b></b>-->
<span>配送信息</span>
</div>
</div>
</div>

<div id="address">
	<div class="addr-list">
		<ul>
			<?php if(!empty($Address)){ foreach ($Address as $k=>$v){?>
				<li class="addli" attr="<?php echo $v['adid']?>">
					<div class="inner">
						<div class="addli-top">
							<span class="span1"><?php echo $v['adname']?></span>
							<span class="span1">
								<span class="prov">（<?php echo $v['location']?>）</span>
							</span>
						</div>
						<div class="addli-mid">

							<span><?php echo $v['address']?></span>
							<span><?php echo $v['phone']?></span>
						</div>
						<div class="addli-bot" style="text-align: right;">
							<span class="bot-span">
								<a href="JavaScript:if(confirm('确认删除吗?')) location.href='<?php echo u('del',['adid'=>$v['adid']])?>'">删除</a>
							</span>
						</div>
					</div>
				</li>
			<?php }}?>
			<li class="addli2">
				<div class="inner">
					<p>添加新地址</p>
				</div>
			</li>
		</ul>
	</div>
</div>

<div id="all">
	<div class="all-inner">
	</div>
</div>
	
<div id="new">
	<div class="new-inner">
		<div class="title">
			<h3>新增配送信息</h3>
		</div>
		<a href="" class="close" title="关闭"></a>
		<form action="<?php echo u('index')?>" id="form" method="post"  >
			<div class="content">
				<dl>
					<dt>
					<div class="f1" style="overflow: hidden;">
						<span>
							<p>*</p>配送方式：
						</span>
					</div>
					<div class="f1right" >
						<b></b>
						<span>配送上门</span>
					</div>
					</dt>
					<dd>
						<div class="f2">
							<div class="f2l">
								<b>*</b>收货人：
							</div>
							<div class="f2r">
								<input type="text" name="adname" placeholder="姓名，如张三，Lily" />
							</div>
						</div>
						<div class="f2">
							<div class="f2l">
								<b>*</b>手机：
							</div>
							<div class="f2r">
								<input type="text" name="phone" placeholder="请填写正确的11位手机号" />
							</div>
						</div>
						<div class="f2">
							<div class="f2l">
								<b>*</b>所在地区：
							</div>
							<div class="f2r">
								<select name="location[]" id="area1"></select>
								<select name="location[]" id="area2"></select>
								<select name="location[]" id="area3"></select>
							</div>
						</div>
						<div class="f2">
							<div class="f2l">
								<b>*</b>详细地址：
							</div>
							<div class="f2r">
								<input type="text" name="address"  placeholder="详细地址" />
							</div>
						</div>
						<div class="f7">
							<input type="checkbox" name="" id="" value="<?php echo Q('adid')?>" />
							<span> 设为默认收货地址</span>
						</div>
					</dd>
				</dl>
				<div class="save">
					<input type="submit" value="保存">
				</div>
			</div>
		<input type='hidden' name='__TOKEN__' value='65d5d3aae784fd462b0e1fb95e36ddcc'/></form>
	</div>
</div>

<div id="pay">
<div class="top-bcheck">
<!--<b></b>-->
<span>支付方式</span>
</div>
<ul>
<li class="payli1">在线支付</li>
<li class="payli2" style="border: 2px solid #DDDDDD;">门店付款</li>
</ul>
</div>
<form action="<?php echo u('order')?>" id="form" method="post">
	<div id="message">
		<div class="top-bcheck">
			<span>商品及服务信息</span>
			<a href="<?php echo u('joinCart.index')?>">返回我的购物车修改</a>
		</div>

			<table class="mbody">
				<tr>
					<th class="mbody-th" style="width: 55%;">
						<span>
							<a href="">商品</a>
						</span>
						<a href="" class="lion"></a>
					</th>
					<th style="width: 352px;">服务信息</th>
					<th style="width: 100px;">单价</th>
					<th style="width: 72px;">数量</th>
					<th style="width: 118px;">小计</th>
				</tr>
				<?php if(!empty($_SESSION['cart']['goods'])){ foreach ($_SESSION['cart']['goods'] as $k=>$v){?>
					<tr>
						<td class="mbody-td">
							<div class="b2">
								<a href="">
									<img src="<?php echo $v['pic']?>" />
								</a>
							</div>
							<div class="b3">
								<p>
									<a href="" title=""><?php echo $v['name']?><?php echo $v['options']?></a>
								</p>
								<p>
									<a href="" style="color: #999999;">7天无理由退货</a>
								</p>
							</div>
						</td>
						<td style="text-align: center;">支付完成后尽快为您发货</td>
						<td class="mbody-td2">
							<p>¥<?php echo $v['price']?>.00</p>
						</td>
						<td style="text-align: center;"><?php echo $v['num']?></td>
						<td style="text-align: center;"><?php echo $v['total']?>.00</td>
					</tr>
				<?php }}?>
					<tr>
						<td class="mbody-td4" colspan="2">
							<span>给卖家留言：</span>
							<textarea name="remark" rows="" cols=""></textarea>
						</td>
						<td class="mbody-td2">
							<p>合计(含运费) </p>
						</td>
						<td style="text-align: center;">免运费</td>
						<td style="text-align: center;color: #FF4400;"><?php echo $_SESSION['cart']['total']?>.00</td>
					</tr>

			</table>

	</div>

	<div id="submit">
		<p class="s-price">
			<span>应付金额：</span>
			<b>￥</b>
				<b class="bb"><?php echo $_SESSION['cart']['total']?></b>
			<b>.00</b>
		</p>
		<p class="s-price2">
			<!--<span>收货信息：</span>-->
			<span title="" class="spantitle">您需先选择配送地址，再提交订单</span>
			<span title="" class="spantitle2">已选地址，请提交订单</span>
		</p>
		<p class="s-price3">
			<span>支付方式：</span>
			<span class="spantitle">在线支付</span>
		</p>
		<div class="s-price4">
			<input type="hidden" name="adid" class="address" value="">
			<input type="submit" name="" id="" value="提交订单" class="s-price-in" />
		</div>

	</div>
<input type='hidden' name='__TOKEN__' value='65d5d3aae784fd462b0e1fb95e36ddcc'/></form>

</body>
</html>
<script>
	$(function(){
		$('.addli').click(function(){
			var adid =$(this).attr('attr');
			$('.address').val(adid);
		});
	})
</script>

